home *** CD-ROM | disk | FTP | other *** search
/ Network Support Library / RoseWare - Network Support Library.iso / btrieve / btr61m.exe / 06CH3A.TXT < prev    next >
Text File  |  1993-07-16  |  22KB  |  643 lines

  1. 3       INSTALLING AND CONFIGURING BTRIEVE
  2.  
  3. This chapter describes how to install and configure
  4. Btrieve.  It discusses the following topics:
  5.  
  6. o Installing Btrieve
  7. o Configuring Btrieve
  8. o Starting and Stopping Btrieve
  9. o Rebuilding Existing Btrieve Files
  10. o Using Btrieve with NetWare Runtime
  11.  
  12.  
  13. Installing Btrieve
  14.  
  15. The following sections discuss the system requirements
  16. and the installation procedure for Btrieve v6.1.
  17.  
  18.  
  19. System Requirements
  20.  
  21. Make sure your system has the following:
  22.  
  23. o NetWare v3.11
  24.  
  25.   NOTE: Running Btrieve v6.1 in a NetWare v3.11 environment
  26.   requires AFTER311.NLM, which Btrieve loads
  27.   automatically.
  28.  
  29. o Adequate memory at the server to load the Btrieve NLM
  30.   (approximately 528 KB) and the appropriate
  31.   communications modules.
  32.  
  33.   NOTE: The memory required for the
  34.   communications modules varies, depending on the
  35.   values you specify for the Largest Record Size and
  36.   Number of Remote Sessions configuration options.
  37.  
  38. o Adequate memory for the Btrieve Requester at each
  39.   workstation.  Memory requirements vary, depending on
  40.   the parameters you specify when you load the
  41.   Requester.  These are the default parameters:
  42.  
  43.   o The DOS Requester requires approximately 29 KB.
  44.  
  45.   o The OS/2 Requester requires approximately 40 KB.
  46.  
  47.   o The Windows Requester requires approximately 30 KB.
  48.     (To use the Windows Requester, you must also have
  49.     the DOS Requester loaded.)
  50.  
  51.     NOTE: Btrieve also provides a requester for the
  52.     UnixWare environment.  For information about this
  53.     new UnixWare Requester, please refer to the Readme
  54.     file that accompanies this release.
  55.  
  56.  
  57. Using the NetWare INSTALL Utility
  58.  
  59. To install Btrieve, complete the following steps:
  60.  
  61. 1.  Enter load install at the server console.
  62.  
  63. 2.  In response to the Installation Options menu,
  64. select Product Options to display the list of
  65. currently installed products.
  66.  
  67. 3.  Press the Insert key to copy Btrieve v6.x program
  68. files to your server.  The system responds with the
  69. following prompt:
  70.  
  71. Enter drive and/or path to new product source media
  72.  
  73. 4.  In response to the prompt, specify the location of
  74. the source media.
  75.  
  76. The default response, A; appears in the response
  77. field.  Use the default if you are installing from the
  78. distribution diskette.  If you are installing from
  79. another source (for example, a NetWare volume and
  80. path), enter the source volume and path at this time.
  81. If the source media is not on the distribution
  82. diskette, the source media you use must have the same
  83. directory structure as that found on the distribution
  84. diskette.
  85.  
  86. 5.  When the Copy Btrieve Files to Fileserver menu
  87. appears, select Copy Files.
  88.  
  89. 6.  When the Existing Btrieve Program Files menu
  90. appears, select either Overwrite or Rename.
  91.  
  92. o Overwrite - This option copies the Btrieve v6.x
  93.   programs over the existing Btrieve programs.
  94.  
  95.   NOTE: The Overwrite option does not overwrite or rename
  96.   existing Btrieve data files.
  97.  
  98. o Rename - This option renames your existing Btrieve
  99.   programs so that you can run either the earlier
  100.   version of Btrieve and Btrieve v6.x.  If you choose
  101.   this option, the utility changes the first letter of
  102.   the file extension for your existing Btrieve programs
  103.   to $.  For example, program files that had the
  104.   extension .NLM now have the extension .$LM, and
  105.   program files with the extension .NCF now have the
  106.   extension .$CF.
  107.  
  108. 7.  When the Insert bstart Into...  menu appears,
  109. select the appropriate option.
  110.  
  111. o SYS:\SYSTEM\STARTUP.NCF - This option places
  112.   BSTART.NCF (the Btrieve batch file) into the
  113.   network's STARTUP.NCF file.
  114.  
  115. o SYS:\SYSTEM\AUTOEXEC.NCF - This option places
  116.   BSTART.NCF into your server's AUTOEXEC.NCF file.
  117.  
  118. o You Specify Drive, Path, and AUTOEXEC or STARTUP
  119.   - This option lets you place BSTART.NCF into an
  120.   AUTOEXEC.NCF or STARTUP.NCF file in a directory other
  121.   than SYS:\SYSTEM.  For example, if you loaded NetWare
  122.   from a network drive, you might specify that your
  123.   AUTOEXEC.NCF file be loaded at L:\MYDIR\NW311.
  124.  
  125. o Exit - This option lets you choose to invoke
  126.   BSTART.NCF manually.  If you choose this option, you
  127.   exit the menu.  When installation is complete, the
  128.   utility displays the following:  Program Files
  129.   Successfully Copied to Fileserver
  130.  
  131. 8.  To verify that the correct files are installed on
  132. your server, press Esc to return to the Copy Btrieve
  133. Files to Fileserver menu and select View Log of files
  134. Copied.  A list of files copied (similar to the
  135. following illustration) appears.  Compare this list to
  136. the list of files in the release notes that accompany
  137. the product shipment.
  138.  
  139. 9.  After verifying the copied files, press Esc to
  140. return to the Installation Options menu.
  141.  
  142. 10.  Select Exit to go to the Currently Installed
  143. Products menu.  Btrieve is listed as an option under
  144. the Currently Installed Products menu.
  145.  
  146. 11.  Highlight Btrieve and press Enter to invoke the
  147. Btrieve Setup utility.  The Available Options menu
  148. appears.  This menu provides the following options:
  149.  
  150. o Set Btrieve Configuration - Use this option to view
  151.   or modify the current configuration options for
  152.   Btrieve.
  153.  
  154. o Set Rebuild Configuration - Use this option to view
  155.   or modify the current configuration options for the
  156.   Rebuild utility.  ("Rebuilding Existing Btrieve
  157.   Files"  discusses the Rebuild utility and
  158.   its configuration options.)
  159.  
  160.   If you do not want to set
  161.   configuration options or rebuild Btrieve files at
  162.   this point, press Esc until you exit the INSTALL
  163.   utility.
  164.  
  165. After loading Btrieve with the INSTALL utility, you
  166. can configure Btrieve according to your Btrieve
  167. application's requirements.  Use the guidelines
  168. discussed in the next section, "Configuring Btrieve."
  169. You can then activate Btrieve as discussed in "Starting
  170. and Stopping Btrieve."
  171.  
  172.  
  173. Configuring Btrieve
  174.  
  175. You can configure Btrieve by setting configuration
  176. options.  When you load Btrieve with the INSTALL
  177. utility, these options are set to their default
  178. values.  (Table 3-1 shows the default values.)
  179. However, your Btrieve application may require
  180. different values for these options.
  181.  
  182. To determine which values your application requires,
  183. refer to the documentation included with that
  184. application.
  185.  
  186. Table 3-1 - Default Values for Configuration Options
  187.  
  188. Configuration Option            Default Value
  189.  
  190. Number of Open Files            20 files
  191.  
  192. Number of Handles            60 handles
  193.  
  194. Number of Locks             20 per client
  195.  
  196. Number of Transactions            15 transactions
  197.  
  198. Largest Compressed Record Size        0 KB
  199.  
  200. Largest Record Size            8,192 bytes
  201.  
  202. Largest Page Size            4,096 bytes
  203.  
  204. Number of Remote Sessions        15 sessions
  205.  
  206. Cache Allocation            256 KB
  207.  
  208. Perform Index Balancing         No
  209.  
  210. Logging of Selected Files        No
  211.  
  212. Create Btrieve Files in Pre v6.x Format No
  213.  
  214. Create Files as Transactional        No
  215.  
  216. Configure BSTART.NCF to Load BROUTER    No
  217.  
  218. The following section discusses each configuration
  219. option individually.  You can change the values for
  220. the configuration options by running the Btrieve Setup
  221. utility (as described in "Running the Setup Utility").  The Setup
  222. utility stores your changes in the BSTART.NCF NetWare
  223. command file.
  224.  
  225.  
  226. Configuration Options
  227.  
  228. This section lists the Btrieve configuration options
  229. in the order in which they appear in the Setup
  230. utility.  For each option, the discussion includes the
  231. following:
  232.  
  233. o  Range of acceptable values
  234. o  Default value
  235. o  Approximate memory required
  236. o  Description of the option
  237.  
  238.  
  239. Number of Open Files
  240. Range: 1 through 64,000 files
  241. Default: 20 files
  242. Approximate Memory Required: 425 bytes per file
  243.  
  244. This option specifies the maximum number of unique
  245. Btrieve files that can be open at one time at the
  246. server.  The value you specify determines the size of
  247. the internal tables used to track active files.  Each
  248. unique Btrieve file on the server counts as one file.
  249.  
  250.  
  251. Number of Handles
  252. Range: 1 through 64,000 file handles
  253. Default: 60 handles
  254. Approximate Memory Required: 200 bytes per handle
  255.  
  256. This option specifies the maximum number of file
  257. handles that the Btrieve NLM can use at one time.
  258. Keep in mind that the number of handles is different
  259. from the number of open files.  That is, if two
  260. sessions open the same file on the same server,
  261. Btrieve counts it as one open file, but two different
  262. file handles.  See "Number of Locks" (next) for a
  263. definition of sessions.
  264.  
  265.  
  266. Number of Locks
  267. Range: 0 through 64,000 locks
  268. Default: 20 locks per client session
  269. Approximate Memory Required: 20 bytes per lock
  270.  
  271. This option sets the maximum number of records a
  272. client session can lock at the server at one time.  (A
  273. session occurs when a client uses the Btrieve
  274. Requester or Message Router to communicate with the
  275. Btrieve NLM, or when an NLM application calls Btrieve
  276. directly.) This maximum applies to whichever type of
  277. read lock (single record or multiple record) the
  278. client session is using.  Single-record locks allow an
  279. application to lock only one record at a time.
  280. Multiple-record locks allow an application to lock more
  281. than one record at a time.
  282.  
  283.  
  284. Number of Transactions
  285. Range: 0 through 64,000 transactions
  286. Default: 15 transactions
  287. Approximate Memory Required:  20 bytes + (2 * maximum
  288.       number of files)
  289.  
  290. This option sets the maximum number of Btrieve clients
  291. that can simultaneously have active transactions at
  292. the server.  (Each of these clients can have only one
  293. active transaction at the server.) For example, if you
  294. specify 6 transactions, Btrieve creates a transaction
  295. file at the server (BTRIEVE.TRN in the SYS:SYSTEM
  296. directory) and allows a maximum of 6 clients to have
  297. one active transaction each at the server.  If you
  298. specify a value of 0, no clients can perform a Btrieve
  299. transaction.
  300.  
  301.  
  302. Largest Compressed Record Size
  303. Range: 0 through 64 KB
  304. Default: 0 KB
  305. Approximate Memory Required:  2,048 bytes * specified
  306.          value
  307.  
  308. This option allows you to allocate memory for a
  309. compression buffer that Btrieve can use when you
  310. access records in a Btrieve file created with the Data
  311. Compression file attribute enabled.  Btrieve allocates
  312. a compression buffer with a size of 2,048 bytes
  313. multiplied by the value you specify for this option.
  314. Use the following guidelines when specifying the value
  315. for this option:
  316.  
  317. o If you use compressed Btrieve files, determine the
  318.   size (in bytes) of the largest record in any of your
  319.   compressed files.  Round the record size to the next
  320.   whole kilobyte.  For example, if the largest record
  321.   you need to access is 1,800 bytes, specify 2 for this
  322.   option.  Btrieve will allocate 4,096 bytes (that is,
  323.   2,048 * 2) of memory for the compression buffer.
  324.  
  325. o If every compressed file you use has Variable-tail
  326.   Allocation Tables (VATs), set this option to the
  327.   file's largest page size (in bytes) divided by 128.
  328.   For example, if the largest page size is 1,024 bytes,
  329.   specify 8 for this option.  Btrieve will allocate
  330.   16,384 bytes (that is, 2,048 * 8) of memory for the
  331.   compression buffer.
  332.  
  333. o If you do not use compressed files, set this value
  334.   to 0.  You cannot improve performance, and may waste
  335.   memory, by specifying a value higher than you need.
  336.  
  337.  
  338. Largest Record Size
  339. Range: 600 through 64,000 bytes
  340. Default: 8,192 bytes
  341. Approximate Memory Required: recordLength *
  342.    (remoteSessions /5) + 1 +
  343.    (remoteSessions * recordLength / 580) * 600
  344.  
  345. recordLength            538 + largest record size
  346. remoteSessions          Number of remote sessions
  347.  
  348. This option specifies the length of the largest record
  349. or record chunk that any remote Btrieve application
  350. (excluding other NLMs that call Btrieve, such as
  351. NetWare SQL) can access at the server.  A record chunk
  352. is any arbitrary portion of a record, specified by its
  353. offset and length.  Specify the length of the record
  354. (or record chunk) in bytes.  Specifying a value higher
  355. than you need does not improve performance and may
  356. waste memory.
  357.  
  358. NOTE: For applications running on workstations, the maximum
  359. record length is 57,000 for the DOS Requester, 65,000
  360. for the OS/2 Requester, and 57,000 for the Windows
  361. Requester.
  362.  
  363.  
  364. Largest Page Size
  365. Range: 512 through 4,096 bytes
  366. Default: 4,096 bytes
  367. Approximate Memory Required: Not applicable
  368.  
  369. This option specifies the maximum page size (in bytes)
  370. of any Btrieve file you want to access.  The page size
  371. must be a multiple of 512 bytes, but no greater than
  372. 4,096 bytes.  Setting the page size to 512, 1,024,
  373. 2,048, or 4,096 can improve performance because these
  374. page sizes correspond to disk block sizes.  If you set
  375. the page size to 1,536, 2,560, 3,072, or 3,584, a
  376. given disk read may span two disk blocks and therefore
  377. require two disk accesses per page.
  378.  
  379.  
  380. Number of Remote Sessions
  381. Range: 1 through 64,000 sessions
  382. Default: 15 sessions
  383. Approximate Memory Required:  150 bytes * number of
  384. remote sessions
  385.  
  386. This option specifies the maximum number of SPX
  387. sessions that can access the remote Btrieve NLM at one
  388. time.  (A session occurs when a client uses the
  389. Btrieve Requester or the Message Router to communicate
  390. with the remote Btrieve NLM.) Each session is allocated
  391. two packet buffers for Btrieve requests.
  392.  
  393. NOTE: If you
  394. receive a Status Code 96, increase the value for this
  395. option.  However, do not specify a value higher than
  396. you need.  Specifying a value that is too high does
  397. not improve performance; instead, it uses memory that
  398. NetWare or other processes might need.
  399.  
  400.  
  401. Cache Allocation
  402. Range: 32 through 64,000 KB
  403. Default: 256 KB
  404. Approximate Memory Required: Not applicable
  405.  
  406. This option specifies the size of the cache (in
  407. kilobytes) that Btrieve allocates.  To achieve best
  408. performance, allocate a cache size equal to the sum of
  409. the sizes of the files you are using.  However, be
  410. careful not to take all available cache, especially if
  411. the server is running other applications.  You cannot
  412. improve performance, and may waste memory, by
  413. specifying a value higher than you need.
  414.  
  415.  
  416. Perform Index Balancing
  417. Range: Yes or No
  418. Default: No
  419. Approximate Memory Required:  Not applicable
  420.  
  421. When an index page becomes full, Btrieve automatically
  422. creates a new index page and splits the values in the
  423. full index page between the two index pages.  The
  424. Perform Index Balancing option lets you avoid creating
  425. a new index page every time an old one fills up.
  426.  
  427. If you specify Yes for this option, Btrieve looks for
  428. available space in sibling index pages each time an
  429. index page becomes full.  Btrieve then rotates values
  430. from the full index page into the pages that have
  431. space available.  Index balancing increases index page
  432. utilization, results in fewer index pages, and
  433. produces an even distribution of keys among nodes on
  434. the same level, thus increasing performance during Get
  435. operations.  However, when you specify Yes for this
  436. option, Btrieve requires extra time to examine more
  437. index pages and may require more disk I/O during
  438. Insert, Update, and Delete operations.
  439.  
  440. NOTE: You can also specify index balancing on a file-by-file
  441. basis by setting a bit in the file flag╒s word when
  442. the file is created.  If you specify Yes to the
  443. Perform Index Balancing option, Btrieve performs index
  444. balancing on every file regardless of the balanced
  445. file flag specification.
  446.  
  447.  
  448. Logging of Selected Files
  449. Range: Yes or No
  450. Default: No
  451. Approximate Memory Required: Not applicable
  452.  
  453. This option controls whether Btrieve logs operations
  454. executed on selected files.  If you specify Yes,
  455. Btrieve logs all operations that change any file
  456. listed in the BLOG.CFG file on Btrieve╒s server
  457. volume.  If you specify No, Btrieve performs no
  458. logging.  For more information on logging and the Roll
  459. Forward utility, see Chapter 5, "Using Btrieve
  460. Utilities."
  461.  
  462.  
  463. Create Btrieve Files in Pre v6.x Format
  464. Range: Yes or No
  465. Default: No
  466. Approximate Memory Required: Not applicable
  467.  
  468. This option specifies that all files be created in a
  469. Btrieve version prior to v6.x.  Use this option only
  470. if you need backward compatibility with a previous
  471. version of Btrieve.  For example, if you want to
  472. create files with Btrieve v6.x and you want to use
  473. those files with Btrieve v5.x, specify Yes for this
  474. option.
  475.  
  476. NOTE: Btrieve v6.x can read files that previous
  477. versions of Btrieve created.  In addition, it can
  478. write to files using the existing file format.  In
  479. other words, it writes to v5.x files using the v5.x
  480. format and writes to v6.x files using the v6.x format.
  481.  
  482.  
  483. Create Files as Transactional
  484. Range: Yes or No
  485. Default: No
  486. Approximate Memory Required: Not applicable
  487.  
  488. This option controls whether Btrieve automatically
  489. flags each file as transactional when you create it.
  490. The transactional flag indicates that the NetWare
  491. Transaction Tracking System (TTS) is protecting the
  492. file.  TTS ensures that, when a file is being
  493. modified, either all changes are made or no changes
  494. are made, thus preventing data damage.
  495.  
  496.  
  497. Configure BSTART.NCF to Load BROUTER
  498. Range: Yes or No
  499. Default: No
  500. Approximate Memory Required: Not applicable
  501.  
  502. This option controls whether the Message Router is
  503. loaded during the execution of the BSTART.NCF NetWare
  504. command file.  The Message Router allows other NLMs
  505. (such as NetWare SQL) to communicate with remote
  506. servers on which Btrieve is loaded.  If you want to
  507. access Btrieve data on a remote server, specify Yes
  508. for this option.
  509.  
  510.  
  511. Running the Setup Utility
  512.  
  513. Use the Setup utility to set the Btrieve configuration
  514. options interactively.  The utility automatically
  515. checks to see if the values you enter are within the
  516. correct ranges.  You can run the Setup utility either
  517. at the server console or at a workstation running the
  518. NetWare Remote Console utility (RCONSOLE).
  519.  
  520. To run the Setup utility, complete the following steps.
  521.  
  522. NOTE: To get help with the Setup utility, press F1.  The
  523. help information is context sensitive, relevant to
  524. your location in the program.  To exit the utility,
  525. press the Esc key.
  526.  
  527. 1.  Enter load bsetup at the prompt to start the
  528. utility.  If your SYS:SYSTEM directory does not
  529. contain the BSTART.NCF command file, the Setup utility
  530. displays a window asking if you want to create it.  If
  531. that window appears on your screen, create the
  532. BSTART.NCF file at this time.
  533.  
  534. The Available Options menu appears.
  535.  
  536. This menu provides the following options:
  537.  
  538. o Set Btrieve Configuration - Use this option to view
  539.   or modify the current configuration options for
  540.   Btrieve.
  541.  
  542. o Set Rebuild Configuration - Use this option to run
  543.   the Rebuild utility, view or modify the current
  544.   Rebuild configuration options, and view the Rebuild
  545.   log file.  ("Rebuilding Existing Btrieve Files"
  546.   discusses the Rebuild utility and its configuration
  547.   options.)
  548.  
  549. 2.  To change configuration options, select Set
  550. Btrieve Configuration.
  551.  
  552. 3.  When the Current Btrieve Configuration screen
  553. appears, use the Up- and Down-Arrow keys to highlight
  554. the configuration option you want to change, and press
  555. the Enter key.  A flashing cursor appears.
  556.  
  557. 4.  Use the Backspace key to remove the old value;
  558. then, type the new value and press the Enter key.
  559.  
  560. If you enter an invalid value for an option, the utility
  561. displays a message indicating the valid values.
  562.  
  563. NOTE: To see the valid values for any option, move the cursor
  564. to that option, press the Enter key, and then press
  565. the F1 key.  You can also refer to "Configuration
  566. Options" for more information about these
  567. options and their values.
  568.  
  569. 5.  Repeat Steps 3 and 4 until you have changed all
  570. the options you want to modify.
  571.  
  572. 6.  When you are ready to exit the Current Btrieve
  573. Configuration screen, press the Esc key.
  574.  
  575. 7.  When the Save Configuration Changes?  screen
  576. appears, select Yes to save your changes or No to
  577. abandon the changes.
  578.  
  579. If you select Yes, the Setup utility writes the
  580. configuration values you specified to the BSTART.NCF
  581. file.
  582.  
  583. IMPORTANT: Do not edit the BSTART.NCF command file for
  584. Btrieve.  Always use the Setup utility to make any
  585. modifications to the configuration values in the
  586. BSTART.NCF file.
  587.  
  588. Before your configuration changes can take effect, you
  589. must unload the existing Btrieve NLM, BSPXCOM, and the
  590. Message Router (using the BSTOP command), and then
  591. reload them by entering the BSTART command.
  592.  
  593. BSTOP.NCF does not unload BSPXSTUB or RSPXSTUB.  To unload these
  594. modules, type UNLOAD followed by the module name.
  595.  
  596. 8.  To exit the Setup utility, press the Esc key until
  597. the Exit window appears, and then select Yes.
  598. Starting and Stopping Btrieve
  599.  
  600. This section discusses starting and stopping Btrieve.
  601. Before starting Btrieve v6.x, you must first check for
  602. any extraneous pre-image files (files with a .PRE
  603. extension) and then unload the earlier version of
  604. Btrieve.
  605.  
  606. NOTE: If you need to preserve your Btrieve v5.x files, you
  607. can use Btrieve v6.x to read them.
  608.  
  609.  
  610. Checking for Extraneous Pre-Image Files
  611.  
  612. If you have any extraneous .PRE files in your
  613. database, you must remove them before starting Btrieve
  614. v6.x.  The following procedure explains how to check
  615. for and remove extraneous .PRE files.
  616.  
  617. IMPORTANT:  You must have
  618. Btrieve v5.x or v6.0 loaded before performing these
  619. steps.
  620.  
  621. 1.  Using your existing version of Btrieve (such as
  622. v5.x or v6.0), open the Btrieve data file
  623. corresponding to the .PRE file in Exclusive mode.
  624.  
  625. 2.  Perform a Get First operation.
  626.  
  627. 3.  Perform an Update operation (this will not change
  628. the record).
  629.  
  630. 4.  Close the Btrieve data file (this should cause
  631. Btrieve to delete the .PRE file).
  632.  
  633. 5.  Any .PRE files that remain for the designated file
  634. after you perform Steps 1 through 4 are extraneous.
  635. Delete them at this time.
  636.  
  637. 6.  Repeat Steps 1 through 5 to find and delete any
  638. other extraneous .PRE files.
  639.  
  640. IMPORTANT: If you do not remove the extraneous .PRE files before
  641. starting Btrieve v6.x, file corruption may occur.
  642.  
  643.